<include file="public@header" />
<style>
	.controls{ color:#999}
	.minwidth{width:55px !important}
	div[name='d_gaiban'],div[name='d_al']{ width:100%;float:left;}
	.form-horizontal .control-group1{}
</style>
</head>
<body>
	<php>$type=''</php>
	<div class="wrap">
		<ul class="nav nav-tabs">
			<li><a href="{:url('Rock/product')}">石材产品库</a></li>
			<li class="active"><a href="{:url('Rock/productadd')}">新增产品库</a></li>
		</ul>
		<form method="post" class="form-horizontal js-ajax-form" action="{:url('Rock/productadd_post')}" style="width:100%; float:left">
			<fieldset>
				<div class="p_title">
					<span class="span_title">基础信息</span>
				</div>
				<div class="control-group1-p">
					<div class="control-group1" style="width:30%">
						<label class="control-label">产品名称:</label>
						<div class="controls">
							<input type="text" class="form-control" name="pro_name" required value="">
						</div>
					</div>
					<div class="control-group1" style="width:30%">
						<label class="control-label">以旧换新产品:</label>
						<div class="controls">
							<select class="form-control" name="change_id">
								<option value="0" selected></option>
								<volist name="allData" id="vo">
										<option value="{$vo.id}">{$vo.name}</option>
								</volist>
							</select>
						</div>
					</div>
					<div class="control-group1" style="width:30%">
						<label class="control-label">应用位置:</label>
						<div class="controls">
							<input type="text" class="form-control" style="width: 300px" name="pro_address" required value="">
						</div>
					</div>
					<div class="control-group1" style="width:30%">
						<label class="control-label">状态:</label>
						<div class="controls">
							<select class="form-control" name="pro_status">
								<option value="1">在产</option>
								<option value="2">停产</option>
							</select>
						</div>
					</div>
					<div class="control-group1"  style="width:30%">
						<label class="control-label">主材色调:</label>
						<div class="controls">
							<input type="text" class="form-control" style="width: 200px" name="pro_color" required value="">
						</div>
					</div>
					<div class="control-group1" style="width:30%">
						<label class="control-label">产品图</label>
						<div class="controls">
							<input type="hidden" name="pro_photo" id="thumb" value="">
							<a href="javascript:uploadOneImage('图片上传','#thumb');">
								<h5 class="btn btn-primary">上传</h5>
								<img src="" id="thumb-preview"
									 width="135" style="cursor: hand"/>
							</a>
							<input type="button" class="btn btn-sm"
								   onclick="$('#thumb-preview').attr('src','');$('#thumb').val('');return false;"
								   value="取消图片">
						</div>
					</div>
				</div>
                <div class="p_title">
                	<span class="span_title">墓碑信息</span>
                </div>
                <div class="control-group1-p">

            	<div class="control-group1">
					<label class="control-label">碑笠:</label>
					<input type="hidden" name="iname[]" value="碑笠" >
					<input type="hidden" name="isort[]" value="1" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="iwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="iheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="ithick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="icate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="inumber[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" style="width:16%">
					<label class="control-label">维修单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="irepair_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1"  style="width:16%">
					<label class="control-label">更换单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="ichange_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1">
					<label class="control-label">碑傍:</label>
					<input type="hidden" name="iname[]" value="碑傍" >
					<input type="hidden" name="isort[]" value="2" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="iwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="iheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="ithick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
				<div class="control-group1">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="icate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="inumber[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" style="width:16%">
					<label class="control-label">维修单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="irepair_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1"  style="width:16%">
					<label class="control-label">更换单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="ichange_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1">
					<label class="control-label">主碑板:</label>
					<input type="hidden" name="iname[]" value="主碑板" >
					<input type="hidden" name="isort[]" value="3" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="iwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="iheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="ithick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="icate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="inumber[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" style="width:16%">
					<label class="control-label">维修单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="irepair_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1"  style="width:16%">
					<label class="control-label">更换单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="ichange_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1">
					<label class="control-label">副碑板:</label>
					<input type="hidden" name="iname[]" value="副碑板" >
					<input type="hidden" name="isort[]" value="4" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="iwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="iheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="ithick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="icate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="inumber[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" style="width:16%">
					<label class="control-label">维修单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="irepair_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1"  style="width:16%">
					<label class="control-label">更换单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="ichange_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1">
					<label class="control-label">碑座:</label>
					<input type="hidden" name="iname[]" value="碑座" >
					<input type="hidden" name="isort[]" value="5" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="iwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="iheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="ithick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="icate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="inumber[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" style="width:16%">
					<label class="control-label">维修单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="irepair_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1"  style="width:16%">
					<label class="control-label">更换单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="ichange_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" style="width:100%">
					<label class="control-label">基础:</label>
					<div class="controls">
						<select class="form-control" name="pro_base" jichu1 id="select_jichu">
							<option value="1">整石</option>
							<option value="2">贴面</option>
						</select>
					</div>
				</div>
                <div class="control-group1" name="zhengshi">
					<label class="control-label">一级底座前芝台:</label>
					<input type="hidden" name="bname[]" value="一级底座前芝台" >
					<input type="hidden" name="bsort[]" value="1" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1" name="zhengshi">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%" name="zhengshi">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="bnumber[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" style="width:16%" name="zhengshi">
					<label class="control-label">维修单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="brepair_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1"  style="width:16%" name="zhengshi">
					<label class="control-label">更换单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="bchange_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" name="zhengshi">
					<label class="control-label">一级底座侧芝台:</label>
					<input type="hidden" name="bname[]" value="一级底座侧芝台" >
					<input type="hidden" name="bsort[]" value="2" >
					<div class="controls">
						<input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="">
						<input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="">
						<input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
				<div class="control-group1" name="zhengshi">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%" name="zhengshi">
					<label class="control-label">数量:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bnumber[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" style="width:16%" name="zhengshi">
					<label class="control-label">维修单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="brepair_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1"  style="width:16%" name="zhengshi">
						<label class="control-label">更换单价:</label>
						<div class="controls">
							<input type="text" class="form-control" name="bchange_price[]" style="width:100px;" value="">
						</div>
					</div>
				<div class="control-group1" name="zhengshi">
					<label class="control-label">一级底座后芝台:</label>
					<input type="hidden" name="bname[]" value="一级底座后芝台" >
					<input type="hidden" name="bsort[]" value="3" >
					<div class="controls">
						<input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="">
						<input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="" >
						<input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"   value=""> mm
					</div>
				</div>
				<div class="control-group1" name="zhengshi">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%"  name="zhengshi">
					<label class="control-label">数量:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bnumber[]" style="width:100px;"  value="">
					</div>
				</div>
				<div class="control-group1" style="width:16%"  name="zhengshi">
					<label class="control-label">维修单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="brepair_price[]" style="width:100px;"  value="">
					</div>
				</div>
				<div class="control-group1"  style="width:16%"  name="zhengshi">
					<label class="control-label">更换单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bchange_price[]" style="width:100px;"  value="">
					</div>
				</div>
				<div class="control-group1" name="zhengshi">
					<label class="control-label">二级底座前芝台:</label>
					<input type="hidden" name="bname[]" value="二级底座前芝台" >
					<input type="hidden" name="bsort[]" value="4" >
					<div class="controls">
						<input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="" >
						<input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="">
						<input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
				<div class="control-group1" name="zhengshi">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%" name="zhengshi">
					<label class="control-label">数量:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bnumber[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" style="width:16%" name="zhengshi">
					<label class="control-label">维修单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="brepair_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1"  style="width:16%" name="zhengshi">
					<label class="control-label">更换单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bchange_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" name="zhengshi">
					<label class="control-label">二级底座侧芝台:</label>
					<input type="hidden" name="bname[]" value="二级底座侧芝台" >
					<input type="hidden" name="bsort[]" value="5" >
					<div class="controls">
						<input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="">
						<input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="">
						<input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
				<div class="control-group1" name="zhengshi">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%" name="zhengshi">
					<label class="control-label">数量:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bnumber[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" style="width:16%" name="zhengshi">
					<label class="control-label">维修单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="brepair_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1"  style="width:16%" name="zhengshi">
					<label class="control-label">更换单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bchange_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" name="zhengshi">
					<label class="control-label">二级底座后芝台:</label>
					<input type="hidden" name="bname[]" value="二级底座后芝台" >
					<input type="hidden" name="bsort[]" value="6" >
					<div class="controls">
						<input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="">
						<input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="">
						<input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
				<div class="control-group1" name="zhengshi">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%" name="zhengshi">
					<label class="control-label">数量:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bnumber[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" style="width:16%" name="zhengshi">
					<label class="control-label">维修单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="brepair_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1"  style="width:16%" name="zhengshi">
					<label class="control-label">更换单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bchange_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">一级底座前基石:</label>
					<input type="hidden" name="bname[]" value="一级底座前基石" >
					<input type="hidden" name="bsort[]" value="1" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">数量:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bnumber[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">维修单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="brepair_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1"  style="width:16%;display:none" name="tiemian">
					<label class="control-label">更换单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bchange_price[]" style="width:100px;" value="">
					</div>
				</div>

                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">一级底座侧基石:</label>
					<input type="hidden" name="bname[]" value="一级底座侧基石" >
					<input type="hidden" name="bsort[]" value="2" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">数量:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bnumber[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">维修单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="brepair_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1"  style="width:16%;display:none" name="tiemian">
					<label class="control-label">更换单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bchange_price[]" style="width:100px;" value="">
					</div>
				</div>

                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">一级底座面板:</label>
					<input type="hidden" name="bname[]" value="一级底座面板" >
					<input type="hidden" name="bsort[]" value="3" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">数量:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bnumber[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">维修单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="brepair_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1"  style="width:16%;display:none" name="tiemian">
					<label class="control-label">更换单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bchange_price[]" style="width:100px;" value="">
					</div>
				</div>

                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">二级底座踏步前基石:</label>
					<input type="hidden" name="bname[]" value="二级底座踏步前基石" >
					<input type="hidden" name="bsort[]" value="4" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">数量:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bnumber[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">维修单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="brepair_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1"  style="width:16%;display:none" name="tiemian">
					<label class="control-label">更换单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bchange_price[]" style="width:100px;" value="">
					</div>
				</div>

                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">二级底座踏步面板:</label>
					<input type="hidden" name="bname[]" value="二级底座踏步面板" >
					<input type="hidden" name="bsort[]" value="5" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">数量:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bnumber[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">维修单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="brepair_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1"  style="width:16%;display:none" name="tiemian">
					<label class="control-label">更换单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bchange_price[]" style="width:100px;" value="">
					</div>
				</div>

                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">二级底座踏步侧立面:</label>
					<input type="hidden" name="bname[]" value="二级底座踏步侧立面" >
					<input type="hidden" name="bsort[]" value="6" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="bwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="bheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="bthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1" name="tiemian" style="display:none">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="bcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">数量:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bnumber[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1" style="width:16%;display:none" name="tiemian">
					<label class="control-label">维修单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="brepair_price[]" style="width:100px;" value="">
					</div>
				</div>
				<div class="control-group1"  style="width:16%;display:none" name="tiemian">
					<label class="control-label">更换单价:</label>
					<div class="controls">
						<input type="text" class="form-control" name="bchange_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1">
					<label class="control-label">盖板一:</label>
					<input type="hidden" name="pname[]" value="盖板" >
					<input type="hidden" name="psort[]" value="1" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="pwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="pheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="pthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="pcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="pnumber[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" style="width:16%" >
					<label class="control-label">维修单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="prepair_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1"  style="width:14%">
					<label class="control-label">更换单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="pchange_price[]" style="width:85px;" value="">
					</div>
				</div>
                <div class="control-group1" style="float:left;width:2%">
					<div class="btn btn-primary" id="add_gaiban">+</div>
				</div>
                <div class="control-group1" style="width:100%">
					<label class="control-label">有无栏杆:</label>
					<div class="controls">
						<select class="form-control" name="pro_railing" id="select_langan">
							<option value="1">有</option>
							<option value="2">无</option>
						</select>
					</div>
				</div>
                <div class="control-group1" name="langan">
					<label class="control-label">后栏杆柱:</label>
					<input type="hidden" name="rname[]" value="后栏杆柱" >
					<input type="hidden" name="rsort[]" value="1" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="rwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="rheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="rthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1" name="langan">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="rcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%"  name="langan">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rnumber[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" style="width:16%"  name="langan">
					<label class="control-label">维修单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rrepair_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1"  style="width:16%"  name="langan">
					<label class="control-label">更换单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rchange_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" name="langan">
					<label class="control-label">前栏杆柱:</label>
					<input type="hidden" name="rname[]" value="前栏杆柱" >
					<input type="hidden" name="rsort[]" value="2" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="rwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="rheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="rthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1" name="langan">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="rcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%"  name="langan">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rnumber[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" style="width:16%" name="langan">
					<label class="control-label">维修单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rrepair_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1"  style="width:16%" name="langan">
					<label class="control-label">更换单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rchange_price[]" style="width:100px;" value="">
					</div>
				</div>
                
                <div class="control-group1" name="langan">
					<label class="control-label">栏板:</label>
					<input type="hidden" name="rname[]" value="栏板" >
					<input type="hidden" name="rsort[]" value="3" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="rwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="rheight[]" placeholder="高"  value="">
                       <input type="text" class="form-control minwidth" name="rthick[]" placeholder="厚"  value=""> mm
					</div>
				</div>
                <div class="control-group1" name="langan">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="rcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%" name="langan">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rnumber[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" style="width:16%" name="langan">
					<label class="control-label">维修单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rrepair_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1"  style="width:16%" name="langan">
					<label class="control-label">更换单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rchange_price[]" style="width:100px;" value="">
					</div>
				</div>
                <div class="control-group1" name="langan">
					<label class="control-label">抱古:</label>
					<input type="hidden" name="rname[]" value="抱古" >
					<input type="hidden" name="rsort[]" value="4" >
					<div class="controls">
                       <input type="text" class="form-control minwidth" name="rwidth[]" placeholder="宽"  value="">
                       <input type="text" class="form-control minwidth" name="rheight[]" placeholder="高"   value="">
                       <input type="text" class="form-control minwidth" name="rthick[]" placeholder="厚"   value=""> mm
					</div>
				</div>
                <div class="control-group1" name="langan">
					<label class="control-label">石材种类:</label>
					<div class="controls">
						<select class="form-control" name="rcate[]">
							<volist name="cate_type" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" style="width:16%" name="langan">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rnumber[]" style="width:100px;"  value="">
					</div>
				</div>
                <div class="control-group1" style="width:16%" name="langan">
					<label class="control-label">维修单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rrepair_price[]" style="width:100px;"  value="">
					</div>
				</div>
                <div class="control-group1"  style="width:16%" name="langan">
					<label class="control-label">更换单价:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="rchange_price[]" style="width:100px;"  value="">
					</div>
				</div>
                <div class="control-group1" style="width:100%">
					<label class="control-label">有无附件:</label>
					<div class="controls">
						<select class="form-control" name="pro_annex" id="select_fujian">
							<option value="1">有</option>
							<option value="2">无</option>
						</select>
					</div>
				</div>
                <div class="control-group1" name="fujian">
					<label class="control-label">选择附件:</label>
					<div class="controls">
						<select class="form-control" name="annex_id[]">
							<volist name="annex" id="vo">
								<option value="{$vo.id}">{$vo.name}</option>
							</volist>
						</select>
					</div>
				</div>
				<div class="control-group1" name="fujian">
					<label class="control-label">数量:</label>
					<div class="controls">
                       <input type="text" class="form-control" name="anumber[]"   value="">
					</div>
				</div>
				<div class="control-group1" name="fujian" style=" width:50%">
					<div class="btn btn-primary" id="add_fujian">添加附件</div>
				</div>
                
                <!--壁葬-->
                <if condition="$type eq '壁葬'">
					<div class="control-group1">
                        <label class="control-label">格位长度:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">格位纵深:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">格位高度:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">格位规制:</label>
                        <div class="controls">
                            <select class="form-control" name="menu_type">
                                <option value="1">单</option>
                                <option value="2">双</option>
                            </select>
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">安葬类型:</label>
                        <div class="controls">
                            <select class="form-control" name="menu_type">
                                <option value="1">骨灰盒</option>
                                <option value="2">骨灰坛</option>
                                <option value="2">特殊容器</option>
                            </select>
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">销售价格:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">管理周期:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name" style=" width:80px"> 年
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">可寄存:</label>
                        <div class="controls">
                            <select class="form-control" name="menu_type">
                                <option value="1">是</option>
                                <option value="2">否</option>
                            </select>
                        </div>
                    </div>
                </if>
                <!--生态葬-->
                <if condition="$type eq '生态葬'">
                    <div class="control-group1">
                        <label class="control-label">葬区面积:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">葬式:</label>
                        <div class="controls">
                            <select class="form-control" name="menu_type">
                                <option value="1">水葬</option>
                                <option value="2">土葬</option>
                                <option value="3">其他葬式</option>
                            </select>
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">可容纳骨灰总量:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">单次最高安葬量:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">不保留骨灰:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">安葬器皿:</label>
                        <div class="controls">
                            <select class="form-control" name="menu_type">
                                <option value="1">降解坛</option>
                            </select>
                        </div>
                    </div>
                </if>
                <!--艺术墓-->
                <if condition="$type eq '艺术葬'">
                	<div class="control-group1">
                        <label class="control-label">占地规格:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">套内总长:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name" style="width:80px"> M
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">套内总宽:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name" style="width:80px"> M
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">建议使用:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">室内是否含拜道:</label>
                        <div class="controls">
                          <select class="form-control" name="menu_type">
                                <option value="1">是</option>
                                <option value="2">否</option>
                            </select>
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">拜道规格:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">总高限制:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    
                    <div class="control-group1">
                        <label class="control-label">销售价格:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name" style="width:80px">
                           <select class="form-control" name="menu_type" style="width:120px">
                                <option value="1">元/平米</option>
                                <option value="2">元/套</option>
                            </select>
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">质保期:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name">
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">管理周期:</label>
                        <div class="controls">
                            <select class="form-control" name="menu_type">
                                <option value="1">20年</option>
                                <option value="2">50年</option>
                                <option value="3">70年</option>
                            </select>
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">签约套数:</label>
                        <div class="controls">
                           <input type="text" class="form-control" name="name" style="width:80px"> 套
                        </div>
                    </div>
                    <div class="control-group1">
                        <label class="control-label">设计方案:</label>
                        <div class="controls">
                            <input type="text" class="form-control" name="icon" id="action">
                            <a href="http://www.thinkcmf.com/font/icons" target="_blank">选择图片</a>
                        </div>
                    </div>
                </if>
                </div>
			</fieldset>
			<div class="form-actions">
				<button type="submit" class="btn btn-primary js-ajax-submit">{:lang('ADD')}</button>
				<a class="btn btn-default" href="javascript:history.back(-1);">{:lang('BACK')}</a>
			</div>            
		</form>

	</div>
    <script type="text/javascript" src="__STATIC__/js/admin.js?v={:time()}"></script>
	<script type="text/javascript" src="__STATIC__/js/layer/layer.js"></script>
	<script>
		$(document).ready(function(){
			var json = {$annexJson};
			var html = "";
			$.each(json, function(i, n){
				html += "<option value='"+n.id+"'>"+n.name+"</option>";
			})
			var catejson = {$cateJson};
			var catehtml = "";
			$.each(catejson, function(i, n){
				catehtml += "<option value='"+n.id+"'>"+n.name+"</option>";
			})

			$("#select_langan").change(function(){
				if($(this).val()==2){
					$("div[name='langan']").hide();
				}else{
					$("div[name='langan']").show();
				}
			});
			$("#select_fujian").change(function(){
				if($(this).val()==2){
					$("div[name='fujian']").hide();
				}else{
					$("div[name='fujian']").show();
				}
			});
			$("#select_jichu").change(function(){
				if($(this).val()==2){
					$("div[name='tiemian']").show();
					$("div[name='zhengshi']").hide();
				}else{
					$("div[name='tiemian']").hide();
					$("div[name='zhengshi']").show();
				}
			});
			$(document).on('click','#del_fujian',function(){
				$(this).parents("div[name='d_al']").remove();
			});
			$(document).on('click','#del_gaiban',function(){
				$(this).parents("div[name='d_gaiban']").remove();
			});
			$("#add_fujian").click(function(){
				var str = "";
				str = "<div name='d_al'><div class='control-group1' name='fujian'>" +
							"<label class='control-label'>选择附件:</label>" +
							"<div class='controls'>" +
								"<select class='form-control' name='aname[]'>" ;
								str+=html;
								str+="</select>" +
							"</div>" +
						"</div>" +
						"<div class='control-group1' name='fujian'>" +
							"<label class='control-label'>数量:</label>" +
							"<div class='controls'>" +
							   "<input type='text' class='form-control' name='anumber[]'  value=''>" +
							"</div>" +
						"</div>" +
						"<div class='control-group1' name='fujian' style='width:50%'>" +
							"<div class='btn btn-primary' id='del_fujian'>删除附件</div>" +
						"</div></div>"
				
				$(this).parent("div").after(str);
			})
			//添加改版
			$("#add_gaiban").click(function(){
				var str = "";
				str = "<div name='d_gaiban'><div class='control-group1'>"+
					"<label class='control-label'>盖板:</label>"+
					"<input type='hidden' name='pname[]' value='盖板' >"+
					"<input type='hidden' name='psort[]' value=1 >"+
					"<div class='controls'>"+
                       "<input type='text' name='pwidth[]' placeholder='宽' class='minwidth form-control'  value='' style='margin-right:5px'>"+
                       "<input type='text' name='pheight[]' placeholder='高' class='minwidth form-control' value='' style='margin-right:5px'>"+
                       "<input type='text' name='pthick[]' placeholder='厚' class='minwidth form-control' value=''> mm"+
					"</div>"+
				"</div>"+
                "<div class='control-group1'>"+
					"<label class='control-label'>石材种类:</label>"+
					"<div class='controls'>"+
						"<select class='form-control' name='pcate[]'>";
							str+=catehtml;
						str+="</select>"+
					"</div>"+
				"</div>"+
				"<div class='control-group1' style='width:16%'>"+
					"<label class='control-label'>数量:</label>"+
					"<div class='controls'>"+
                       "<input type='text' class='form-control' name='pnumber[]' style='width:100px;' value=''>"+
					"</div>"+
				"</div>"+
                "<div class='control-group1' style='width:16%' >"+
					"<label class='control-label'>维修单价:</label>"+
					"<div class='controls'>"+
                      " <input type='text' class='form-control' name='prepair_price[]' style='width:100px;' value=''>"+
					"</div>"+
				"</div>"+
                "<div class='control-group1'  style='width:14%'>"+
					"<label class='control-label'>更换单价:</label>"+
					"<div class='controls'>"+
                       "<input type='text' class='form-control' name='pchange_price[]' style='width:85px;' value=''>"+
					"</div>"+
				"</div>"+
				"<div class='control-group' style='width:2%;float:left'>" +
					"<div class='btn btn-primary' id='del_gaiban'>-</div>" +
				"</div></div>"
				
				$(this).parent("div").after(str);
			})
		})
	</script>
